/**
 * @Author: 秦建华
 * @Date: 2020/11/24
 * @Last Modified by: max.jianhua
 * @Last Modified time: 2020/11/25
 */
const RouteView = () => import('@/layout/RouteView');
// 异步路由组件加载
const AsyncComponent = __name__ => () => import(`@/pages/${__name__}`);

// 菜单路由
const menuRoutes = [{
  path: '/omFinance',
  meta: {
    title: '财务管理',
    icon: 'el-icon-s-cooperation'
  },
  redirect: '/omFinance',
  component: RouteView,
  children: [{
      path: '/omFinance/RebateRedInvoice',
      meta: {
        title: '返利红票管理'
      },
      redirect: '/omFinance/RebateRedInvoice',
      component: RouteView,
      children: [{
          path: '/omFinance/RebateRedInvoice/RebateRedInvoiceApply',
          meta: {
            title: '返利红票申请',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateRedInvoice/RebateRedInvoiceApply')
        },
        {
          path: '/omFinance/RebateRedInvoice/RebateRedInvoiceApprove',
          meta: {
            title: '返利红票审批',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateRedInvoice/RebateRedInvoiceApprove')
        },
        {
          path: '/omFinance/RebateRedInvoice/RebateRedInvoiceQuery',
          meta: {
            title: '返利红票查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateRedInvoice/RebateRedInvoiceQuery')
        },
      ]
    },
    {
      path: '/omFinance/CRReportManage',
      meta: {
        title: '信用评级报表管理'
      },
      redirect: '/omFinance/CRReportManage',
      component: RouteView,
      children: [{
          path: '/omFinance/CRReportManage/IncomeReportQuery',
          meta: {
            title: '利润表查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/CRReportManage/IncomeReportQuery')
        },
        {
          path: '/omFinance/CRReportManage/CashFlowReportQuery',
          meta: {
            title: '现金流量表查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/CRReportManage/CashFlowReportQuery')
        },
        {
          path: '/omFinance/CRReportManage/CostReportQuery',
          meta: {
            title: '成本费用表查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/CRReportManage/CostReportQuery')
        },
        {
          path: '/omFinance/CRReportManage/BalanceSheetQuery',
          meta: {
            title: '资产负债表查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/CRReportManage/BalanceSheetQuery')
        },
        {
          path: '/omFinance/CRReportManage/CreditStatisticsReport',
          meta: {
            title: '信用统计报表',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/CRReportManage/CreditStatisticsReport')
        },
      ]
    },
    {
      path: '/omFinance/MoneyManage',
      meta: {
        title: '资金管理'
      },
      redirect: '/omFinance/MoneyManage',
      component: RouteView,
      children: [{
          path: '/omFinance/MoneyManage/BankInfoMaintain',
          meta: {
            title: '三方银行信息维护',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/MoneyManage/BankInfoMaintain')
        },
        {
          path: '/omFinance/MoneyManage/RebateFreezingDetailsQuery',
          meta: {
            title: '返利冻结明细查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/MoneyManage/RebateFreezingDetailsQuery')
        },
        {
          path: '/omFinance/MoneyManage/DealerAccountQuery',
          meta: {
            title: '经销商账户查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/MoneyManage/DealerAccountQuery')
        },
        {
          path: '/omFinance/MoneyManage/AccountDetailsQuery',
          meta: {
            title: '账户明细查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/MoneyManage/AccountDetailsQuery')
        },
        {
          path: '/omFinance/MoneyManage/AccountManage',
          meta: {
            title: '账户管理',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/MoneyManage/AccountManage')
        },
        {
          path: '/omFinance/MoneyManage/cms-sapFundBalanceStatement',
          meta: {
            title: 'cms-sap资金余额对账表',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/MoneyManage/cms-sapFundBalanceStatement')
        },
      ]
    },
    {
      path: '/omFinance/FinanceManage',
      meta: {
        title: '三方融资管理'
      },
      redirect: '/omFinance/FinanceManage',
      component: RouteView,
      children: [{
          path: '/omFinance/FinanceManage/RiskDealerListMaintain',
          meta: {
            title: '风险经销商清单维护',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/RiskDealerListMaintain')
        },
      
        // {
        //   path: '/omFinance/FinanceManage/FinancialManagerApproval',
        //   meta: {
        //     title: '事业部财务经理审批',
        //     keepAlive: true
        //   },
        //   component: AsyncComponent('omFinance/FinanceManage/FinancialManagerApproval')
        // },
        {
          path: '/omFinance/FinanceManage/BigCustomerMinisterApproval',
          meta: {
            title: '大客户部部长审批',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/BigCustomerMinisterApproval')
        },
        {
          path: '/omFinance/FinanceManage/MinisterApproval',
          meta: {
            title: '事业部部长审批',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/MinisterApproval')
        },
        {
          path: '/omFinance/FinanceManage/FinanceSectionReview',
          meta: {
            title: '总部金融科评审',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/FinanceSectionReview')
        },
        {
          path: '/omFinance/FinanceManage/FinanceQuery',
          meta: {
            title: '三方融资查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/FinanceQuery')
        },
        {
          path: '/omFinance/FinanceManage/VehicleStorageAgeRemind',
          meta: {
            title: '三方车辆库龄提醒',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/VehicleStorageAgeRemind')
        },
        {
          path: '/omFinance/FinanceManage/InvoiceNumberQuery',
          meta: {
            title: '三方票号查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/InvoiceNumberQuery')
        },
        {
          path: '/omFinance/FinanceManage/LicenseBindingQuery',
          meta: {
            title: '车证绑定查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/LicenseBindingQuery')
        },
        {
          path: '/omFinance/FinanceManage/RepayRecordsImport',
          meta: {
            title: '还款记录导入',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/FinanceManage/RepayRecordsImport')
        },
      ]
    },
    {
      path: '/omFinance/InvoiceMailManage',
      meta: {
        title: '发票邮寄管理'
      },
      redirect: '/omFinance/InvoiceMailManage',
      component: RouteView,
      children: [{
          path: '/omFinance/InvoiceMailManage/GoldenTaxInvoiceQuery',
          meta: {
            title: '金税发票查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/InvoiceMailManage/GoldenTaxInvoiceQuery')
        },
        {
          path: '/omFinance/InvoiceMailManage/SalesListQuery',
          meta: {
            title: '销货清单查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/InvoiceMailManage/SalesListQuery')
        },
        {
          path: '/omFinance/InvoiceMailManage/AddresseeInfoMaintian',
          meta: {
            title: '发票寄/收件人信息维护',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/InvoiceMailManage/AddresseeInfoMaintian')
        },
        {
          path: '/omFinance/InvoiceMailManage/InvoiceMailRegist',
          meta: {
            title: '发票邮寄登记',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/InvoiceMailManage/InvoiceMailRegist')
        },
        {
          path: '/omFinance/InvoiceMailManage/MailSend',
          meta: {
            title: '发票邮寄下发',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/InvoiceMailManage/MailSend')
        },
        {
          path: '/omFinance/InvoiceMailManage/InvoiceMailQuery',
          meta: {
            title: '发票邮寄查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/InvoiceMailManage/InvoiceMailQuery')
        },
        {
          path: '/omFinance/InvoiceMailManage/OldInvoiceAccept',
          meta: {
            title: '旧票接收',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/InvoiceMailManage/OldInvoiceAccept')
        },
        {
          path: '/omFinance/InvoiceMailManage/TiInvoiceReverse',
          meta: {
            title: '线下发票补录',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/InvoiceMailManage/TiInvoiceReverse')
        },
      ]
    },
    {
      path: '/omFinance/RebateManage',
      meta: {
        title: '返利管理'
      },
      redirect: '/omFinance/RebateManage',
      component: RouteView,
      children: [{
          path: '/omFinance/RebateManage/RebateRulesSet',
          meta: {
            title: '返利使用规则设定',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/RebateRulesSet')
        },
        {
          path: '/omFinance/RebateManage/RebatePoolQuery',
          meta: {
            title: '返利池查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/RebatePoolQuery')
        },
        {
          path: '/omFinance/RebateManage/RebatePoolManage',
          meta: {
            title: '返利池管理',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/RebatePoolManage')
        },
        {
          path: '/omFinance/RebateManage/RebateChilrden',
          meta: {
            title: '返利子项目维护',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/RebateChilrden')
        },
        {
          path: '/omFinance/RebateManage/ChildrenCapitalPoolQuery',
          meta: {
            title: '返利子项目资金池查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/ChildrenCapitalPoolQuery')
        },
        {
          path: '/omFinance/RebateManage/ChildrenValidPeriodQuery',
          meta: {
            title: '返利子项目有效期查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/ChildrenValidPeriodQuery')
        },
        {
          path: '/omFinance/RebateManage/RebateDetailsQuery',
          meta: {
            title: '返利明细查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/RebateDetailsQuery')
        },

        {
          path: '/omFinance/RebateManage/RebateStatementGenerate',
          meta: {
            title: '资金返利对账表生成',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/RebateStatementGenerate')
        },
        {
          path: '/omFinance/RebateManage/RebateStatementApproval',
          meta: {
            title: '资金返利对账表审批',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/RebateStatementApproval')
        },
        {
          path: '/omFinance/RebateManage/RebateStatementQuery',
          meta: {
            title: '资金返利对账表查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/RebateManage/RebateStatementQuery')
        },
      ]
    },
    {
      path: '/omFinance/PriceDiscountManage',
      meta: {
        title: '价格折扣管理'
      },
      redirect: '/omFinance/PriceDiscountManage',
      component: RouteView,
      children: [{
          path: '/omFinance/PriceDiscountManage/DiscountRuleMaintain',
          meta: {
            title: '折扣规则维护',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/PriceDiscountManage/DiscountRuleMaintain')
        },
        {
          path: '/omFinance/PriceDiscountManage/OrderBreakdownMaintain',
          meta: {
            title: '订单细分维护',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/PriceDiscountManage/OrderBreakdownMaintain')
        },
        {
          path: '/omFinance/PriceDiscountManage/ProfitAnalysisCodeMaintain',
          meta: {
            title: '获利分析代码维护',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/PriceDiscountManage/ProfitAnalysisCodeMaintain')
        },
        {
          path: '/omFinance/PriceDiscountManage/DiscountStrategyMaintain',
          meta: {
            title: '折扣策略维护',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/PriceDiscountManage/DiscountStrategyMaintain')
        },
        {
          path: '/omFinance/PriceDiscountManage/DiscountStrategyReview',
          meta: {
            title: '折扣策略审核',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/PriceDiscountManage/DiscountStrategyReview')
        },
        {
          path: '/omFinance/PriceDiscountManage/DiscountStrategyQuery',
          meta: {
            title: '折扣策略查询',
            keepAlive: true
          },
          component: AsyncComponent('omFinance/PriceDiscountManage/DiscountStrategyQuery')
        },
      ]
    }
  ]
}];
export default menuRoutes;
